Skip to main content
Glama
route.ts.liquid702 B
/** * Better Auth API Route Handler * * DESIGN PATTERNS: * - Catch-all route for all auth endpoints * - Handles all HTTP methods (GET, POST, etc.) * - Uses Better Auth's built-in API handlers * * CODING STANDARDS: * - Must be at /api/auth/[...all]/route.ts * - Export auth.handler for both GET and POST * - Do not modify unless adding custom middleware * * ENDPOINTS CREATED: * - /api/auth/sign-in, /api/auth/sign-up, /api/auth/sign-out * - /api/auth/session, /api/auth/callback/[provider] * - See Better Auth docs for full API reference */ import { auth } from "@/lib/auth"; import { toNextJsHandler } from "better-auth/next-js"; export const { GET, POST } = toNextJsHandler(auth);

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/AgiFlow/aicode-toolkit'

If you have feedback or need assistance with the MCP directory API, please join our Discord server